import request from '@/utils/request'


export function getGoodsCateList (params:any) {
    return request({
        url: 'store.goodsCate/list',
        method: 'GET',
        params
    })
}

export function createGoodsCate (data:any) {
    return request({
        url: 'store.goodsCate/create',
        method: 'POST',
        data
    })
}
export function updateGoodsCate (data:any) {
    return request({
        url: `store.goodsCate/update`,
        method: 'PUT',
        data
    })
}
export function updateStatusGoodsCate (data:{id:number|string,status:number|string}) {
    return request({
        url: `store.goodsCate/status`,
        method: 'PUT',
        data
    })
}

export function delGoodsCate (data:{id:number|string}) {
    return request({
        url: `store.goodsCate/delete`,
        method: 'DELETE',
        data
    })
}


export function getGoodsCateSelectTree(params:any) {
    return request({
        url: 'store.goodsCate/getSelectTree',
        method: 'GET',
        params
    })
}

export function getGoodsCateDetail (params:{id:number|string}) {
    return request({
        url: `store.goodsCate/detail`,
        method: 'GET',
        params
    })
}

